      INTEGER FUNCTION SEARCH(CNAM)
C! Finds the index for a routine name
      INCLUDE 'params.h'
      INCLUDE 'tables.h'
      CHARACTER*(*) CNAM
C
      SEARCH = 0
      DO 1 I=1,NPROC
         IF(CNAM.EQ.PROCED_NAME(I)) THEN
            SEARCH = I
            RETURN
         ENDIF
   1  CONTINUE
      END
